package com.xidian.zhiancloud.service.riskcontrol.risksystem;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;
import com.xidian.zhiancloud.dao.riskcontrol.risksystem.TControlLevelStatusMapper;
import com.xidian.zhiancloud.model.riskcontrol.TControlLevelStatusList;
import com.xidian.zhiancloud.qo.BaseReqQuery;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 风险管控-系统设置-管控层级
 */
@Service
public class TControlLevelStatusService extends ServiceImpl
        <TControlLevelStatusMapper, TControlLevelStatusList> {

    @Autowired
    TControlLevelStatusMapper tControlLevelStatusMapper;

    public Page<TControlLevelStatusList> getTControlLevelStatusList(
            BaseReqQuery reqdata, Long companyId){
        PageHelper.startPage(reqdata.getPageNum(), reqdata.getPageSize());
        Page<TControlLevelStatusList> pagedata =tControlLevelStatusMapper
                .getTControlLevelStatusList(reqdata.getSearchKey(),companyId);
        return pagedata;
    }

    public int updateTControlLevelStatus
            (Long companyId,String id,String levelSys,String need){
        return tControlLevelStatusMapper.updateTControlLevelStatus
                (companyId,id,levelSys,need);
    }


}
